<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<link type="text/css" href="/css/start/jquery-ui-1.8.21.custom.css" rel="Stylesheet" />	
<link type="text/css" href="/css/1pxtable.css" rel="Stylesheet" />	
<script type="text/javascript" src="/js/jquery-1.7.2.min.js"></script>
<script type="text/javascript" src="/js/jquery-ui-1.8.21.custom.min.js"></script>
<script>
	$(function() {
		$( ".date" ).datepicker({ dateFormat: "yy-mm-dd",firstDay: 1});
	});
	$(document).ready(function(){	
		$('div[id^="notice_"]').fadeOut(2000);
	});

	function toggle(str) {
		var ele = document.getElementById(str);

		if(ele.style.display == "") {
			ele.style.display = "none";
	  	}
		else {
			ele.style.display = "";
		}
	}
</script>
<style type="text/css">
.notice{
position:absolute;
width:100%;height:50px;top:0%;left:0%;
    padding:16px;
    border:2px solid #2266AA;
	font-family:Arial, Helvetica, sans-serif;
    background:#80FFFF;
	text-align:center;
	vertical-align:middle;
	}
</style>



<style type="text/css">
/* <![CDATA[ */

table, td
{
    border-color: #666;
    border-style: solid;
}
table, th
{
    border-color: #666;
    border-style: solid;
}

table
{
    border-width: 0 0 1px 1px;
    border-spacing: 0;
    border-collapse: collapse;
}

td
{
    margin: 0;
    padding: 8px;
    border-width: 1px 1px 0 0;
}
th
{
    margin: 0;
    padding: 8px;
    border-width: 1px 1px 0 0;
}

/* ]]> */
.ipt{
	width:200px;
	}
</style>

</head>

<body style="font-family:Arial, Helvetica, sans-serif">
<?php $arrType = unserialize(PAYROLL_TYPE);
	  $leaveType = unserialize(LEAVE_TYPE);?>
<?php if(!$this->errorFlag){?>
<form id="form1" name="form1" method="post" >
<table width="700" border="0" cellspacing="0" cellpadding="10">
<?php if(!$this->enableSave){
	if($this->showPassword){
	?>	
  <tr>
    <td bgcolor="#FF9999">Password</td>
    <td colspan="2" bgcolor="#FF9999">
      <input type="password" name="password" id="password" />
      <input type="submit" name="btn_submit2" id="btn_submit2" value="Check Password" /></td>
  </tr>
<?php }}?>   
  <tr>
    <td colspan="3"><h2 style="color:#069"> (Basic Information) 
    </h2>
      <a href="/rosteraudit/extend-password" target="_blank">Click Here Extend Passowrd Expire Date</a><br/><br/>
      <a href = "javascript:toggle('leave');">Paid Leave History</a>
      <div id = "leave" style="display:none;">
      	<table width="600" border="1" cellspacing="0" cellpadding="5">
      		<tr>
      			<td>No.</td>
      			<td>Date</td>
      			<td>Type</td>
      			<td>Period</td>
      			<td>Hour</td>
      			<td>Paid Date</td>
      			<td>Note</td>
      		</tr>
      		<?php $i = 1;?>
      		<?php foreach ($this->leaveList as $k2 => $v2){
      				$totalHr += $v2['total_hrs'];?>
      		<tr>
      			<td><?php echo $i++?></td>
      			<td><?php echo $v2['period_start'];?></td>
      			<td><?php echo $leaveType[$v2['period_type']];?></td>
      			<td><?php echo $v2['period_start_hr'].":".str_pad($v2['period_start_min'], 2, "0", STR_PAD_RIGHT)." ~~ ".$v2['period_end_hr'].":".str_pad($v2['period_end_min'], 2, "0", STR_PAD_RIGHT);?></td>
      			<td><?php echo $v2['total_hrs']?></td>
      			<td><?php echo $v2['paid_date']?></td>
      			<?php if(!empty($v2['note'])){?>
      			<td colspan = "2"><?php echo $v2['note']?></td>
      			<?php }else{?>
      			<td><input type = "text" name = "note[<?php echo $v2['id_leave']?>]" size = "10"></input></td>
      			<?php }?>
      		</tr>
      		<?php }?>
      		<tr>
      			<td colspan="3" align = "right">Total Hour</td>
      			<td colspan="2"><?php echo $totalHr?></td>
      			<td colspan="2"><input type = "submit" name = "save" value = "save"></input></td>
      		</tr>
      	</table>
      </div>
      </td>
  </tr>
  <tr>
    <td colspan="3" align="center"><?php 
	echo $this->wStr;
	?></td>
  </tr>
  <tr>
    <td style="width:200px;">Your Email <span style="font-size:12px;">(Read Only Field)</span>:</td>
    <td colspan="2">
      <label for="email_addr"></label>
      <input name="email_addr" type="text" class="ipt" id="email_addr" value="<?php echo $this->stLine['email_staff']; ?>" readonly="readonly"  />
   </td>
  </tr>
  <tr>
    <td>First Names*:<br /></td>
    <td colspan="2"><input name="given_name" type="text" class="ipt" id="given_name" value="<?php echo $this->stLine['first_name']; ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td>Last Name*:<br /></td>
    <td colspan="2"><input name="surname" type="text" class="ipt" id="surname" value="<?php echo $this->stLine['last_name']; ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td>Prefferred Name*:<br /></td>
    <td colspan="2"><input name="pre_name" type="text" class="ipt" id="pre_name" value="<?php echo $this->nickName; ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td>Date Of Birth* :</td>
    <td colspan="2">
    <?php
	$arrDob = explode("-",$this->dob);
	$year = $arrDob[0];
	$month = $arrDob[1];
	$day = $arrDob[2];
	?>
      <select name="day" id="day" <?php echo (!$this->enableSave)?'disabled = "disabled"':'';?>>
          <option value="01" <?php echo ($day == "01")?'selected="selected"':''; ?>  >01</option>
          <option value="02" <?php echo ($day == "02")?'selected="selected"':''; ?>  >02</option>
          <option value="03" <?php echo ($day == "03")?'selected="selected"':''; ?>  >03</option>
          <option value="04" <?php echo ($day == "04")?'selected="selected"':''; ?>  >04</option>
          <option value="05" <?php echo ($day == "05")?'selected="selected"':''; ?>  >05</option>
          <option value="06" <?php echo ($day == "06")?'selected="selected"':''; ?>  >06</option>
          <option value="07" <?php echo ($day == "07")?'selected="selected"':''; ?>  >07</option>
          <option value="08" <?php echo ($day == "08")?'selected="selected"':''; ?>  >08</option>
          <option value="09" <?php echo ($day == "09")?'selected="selected"':''; ?>  >09</option>
          <option value="10" <?php echo ($day == "10")?'selected="selected"':''; ?>  >10</option>
          <option value="11" <?php echo ($day == "11")?'selected="selected"':''; ?>  >11</option>
          <option value="12" <?php echo ($day == "12")?'selected="selected"':''; ?>  >12</option>
          <option value="13" <?php echo ($day == "13")?'selected="selected"':''; ?>  >13</option>
          <option value="14" <?php echo ($day == "14")?'selected="selected"':''; ?>  >14</option>
          <option value="15" <?php echo ($day == "15")?'selected="selected"':''; ?>  >15</option>
          <option value="16" <?php echo ($day == "16")?'selected="selected"':''; ?>  >16</option>
          <option value="17" <?php echo ($day == "17")?'selected="selected"':''; ?>  >17</option>
          <option value="18" <?php echo ($day == "18")?'selected="selected"':''; ?>  >18</option>
          <option value="19" <?php echo ($day == "19")?'selected="selected"':''; ?>  >19</option>
          <option value="20" <?php echo ($day == "20")?'selected="selected"':''; ?>  >20</option>
          <option value="21" <?php echo ($day == "21")?'selected="selected"':''; ?>  >21</option>
          <option value="22" <?php echo ($day == "22")?'selected="selected"':''; ?>  >22</option>
          <option value="23" <?php echo ($day == "23")?'selected="selected"':''; ?>  >23</option>
          <option value="24" <?php echo ($day == "24")?'selected="selected"':''; ?>  >24</option>
          <option value="25" <?php echo ($day == "25")?'selected="selected"':''; ?>  >25</option>
          <option value="26" <?php echo ($day == "26")?'selected="selected"':''; ?>  >26</option>
          <option value="27" <?php echo ($day == "27")?'selected="selected"':''; ?>  >27</option>
          <option value="28" <?php echo ($day == "28")?'selected="selected"':''; ?>  >28</option>
          <option value="29" <?php echo ($day == "29")?'selected="selected"':''; ?>  >29</option>
          <option value="30" <?php echo ($day == "30")?'selected="selected"':''; ?>  >30</option>
          <option value="31" <?php echo ($day == "31")?'selected="selected"':''; ?>  >31</option>
        </select>
      /
      <select name="month" id="month" <?php echo (!$this->enableSave)?'disabled = "disabled"':'';?>>
          <option value="01"  <?php echo ($month == "01")?'selected="selected"':''; ?>   >Jan.</option>
          <option value="02"  <?php echo ($month == "02")?'selected="selected"':''; ?>   >Feb.</option>
          <option value="03"  <?php echo ($month == "03")?'selected="selected"':''; ?>   >Mar.</option>
          <option value="04"  <?php echo ($month == "04")?'selected="selected"':''; ?>   >Apr.</option>
          <option value="05"  <?php echo ($month == "05")?'selected="selected"':''; ?>   >May</option>
          <option value="06"  <?php echo ($month == "06")?'selected="selected"':''; ?>   >June</option>
          <option value="07"  <?php echo ($month == "07")?'selected="selected"':''; ?>   >July</option>
          <option value="08"  <?php echo ($month == "08")?'selected="selected"':''; ?>   >Aug.</option>
          <option value="09"  <?php echo ($month == "09")?'selected="selected"':''; ?>   >Sept.</option>
          <option value="10"  <?php echo ($month == "10")?'selected="selected"':''; ?>   >Oct.</option>
          <option value="11"  <?php echo ($month == "11")?'selected="selected"':''; ?>   >Nov.</option>
          <option value="12"  <?php echo ($month == "12")?'selected="selected"':''; ?>   >Dec.</option>
        </select>
/
<input type="text" name="year" id="year" style="width:50px;" value="<?php echo $year;?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td>Gender*:</td>
    <td colspan="2">
      <select name="gender" id="gender" <?php echo (!$this->enableSave)?'disabled = "disabled"':'';?>>
        <option value="Male" <?php echo ($this->stLine['gender']=='Male')?'selected="selected"':''?> >Male</option>
        <option value="Female"  <?php echo ($this->stLine['gender']=='Female')?'selected="selected"':''?>  >Female</option>
      </select></td>
  </tr>
  <tr>
    <td>Address*:</td>
    <td colspan="2"><label for="addr"></label>
      <textarea name="addr" id="addr" cols="50" rows="3" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ><?php echo $this->stLine['addr_staff']; ?></textarea></td>
  </tr>
  <tr>
    <td>Suburb*:</td>
    <td colspan="2"><input name="suburb" type="text" class="ipt" id="suburb" value="<?php echo $this->stLine['suburb_staff']; ?>"  <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td>State*:</td>
    <td colspan="2">
      <select name="state" id="state" <?php echo (!$this->enableSave)?'disabled = "disabled"':'';?> >
      	<option selected="selected" disabled="true">--Please Select --</option>
        <option value="SA"  <?php echo ($this->stLine['state_staff']=='SA')?'selected="selected"':''?> >SA</option>
        <option value="VIC"  <?php echo ($this->stLine['state_staff']=='VIC')?'selected="selected"':''?>  >VIC</option>
      </select></td>
  </tr>
  <tr>
    <td>Postcode*:</td>
    <td colspan="2"><input name="post_code" type="text" class="ipt" id="post_code" value="<?php echo $this->stLine['postcode']; ?>"  <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>/></td>
  </tr>
  <tr>
    <td>Mobile No.:</td>
    <td colspan="2"><input name="mobile_no" type="text" class="ipt" id="mobile_no" value="<?php echo $this->stLine['mobile_staff']; ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td colspan="3" align="center"><h2 style="color:#069"> (Optional Information)</h2></td>
    </tr>
  <tr>
    <td>Tax File No.(TFN):</td>
    <td colspan="2"><input name="tfn_no" type="text" class="ipt" id="tfn_no" value="<?php echo Model_EncryptHelper::getSslPassword($this->stLine['no_tfn']); ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td>Bank Account BSB:</td>
    <td colspan="2"><input name="bank_bsb" type="text" class="ipt" id="bank_bsb" value="<?php echo Model_EncryptHelper::getSslPassword($this->stLine['bank_bsb']); ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td>Bank Account No.:</td>
    <td colspan="2"><input name="bank_acc_no" type="text" class="ipt" id="bank_acc_no" value="<?php echo Model_EncryptHelper::getSslPassword($this->stLine['bank_acc_no']); ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td>Bank Account Name:</td>
    <td colspan="2"><input name="bank_acc_name" type="text" class="ipt" id="bank_acc_name" value="<?php echo Model_EncryptHelper::getSslPassword($this->stLine['bank_acc_name']); ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td>Credit / Debit Card No.:</td>
    <td colspan="2"><input name="card_no" type="text" class="ipt" id="card_no" value="<?php echo Model_EncryptHelper::getSslPassword($this->stLine['no_credit']); ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> />
    <?php 
	if($this->cdCardFileExist !=''){
	?>
    <span style="float:right;"><a href="<?php echo $this->cdCardFileExist?>" target="_blank"><img src="/im/img-icon.png" border="0" title="Click To Check Uploaded Photo Copy" alt="Check Detail" /></a></span>
    <?php }?>
    </td>
  </tr>
  <tr>
    <td>Medicare Card No.:</td>
    <td colspan="2"><input name="medicare_no" type="text" class="ipt" id="medicare_no" value="<?php echo Model_EncryptHelper::getSslPassword($this->stLine['no_medicare']); ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>  />
    <?php 
	if($this->mcCardFileExist !=''){
	?>
    <span style="float:right;"><a href="<?php echo $this->mcCardFileExist?>" target="_blank"><img src="/im/img-icon.png" border="0" title="Click To Check Uploaded Photo Copy" alt="Check Detail" /></a></span>
    <?php }?>
    </td>
  </tr>
  <tr>
    <td>Student Card No.:</td>
    <td colspan="2"><input name="student_no" type="text" class="ipt" id="student_no" value="<?php echo Model_EncryptHelper::getSslPassword($this->stLine['no_student']); ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>   />
    <?php 
	if($this->stCardFileExist !=''){
	?>
    <span style="float:right;"><a href="<?php echo $this->stCardFileExist?>" target="_blank"><img src="/im/img-icon.png" border="0" title="Click To Check Uploaded Photo Copy" alt="Check Detail" /></a></span>
    <?php }?>
    </td>
  </tr>
  <tr>
    <td colspan="3" align="center"><h2 style="color:#069">( Optional Super Funds)</h2></td>
    </tr>
  <tr>
    <td>Super Company</td>
    <td colspan="2"><select name="super_id_company" id="super_id_company" <?php echo (!$this->enableSave)?'disabled = "disabled"':'';?> >
      <option >Please Select</option>
	<?php foreach($this->spList as $k => $v){?>	
      <option value="<?php echo $v['id_sc']?>"  <?php echo  ($v['id_sc'] == $this->stLine['super_id_company'])?'selected="selected"':'' ?> ><?php echo $v['name_sp']?></option>
	<?php }?>
    </select></td>
  </tr>
  <tr>
    <td>Payment Method</td>
    <td colspan="2"><select name="super_payment_method" id="super_payment_method" <?php echo (!$this->enableSave)?'disabled = "disabled"':'';?> >
      <option>Please Select</option>
	<?php foreach($this->pmList as $k => $v){?>	
      <option value="<?php echo $v['id_method']?>" <?php echo  ($v['id_method'] == $this->stLine['super_payment_method'])?'selected="selected"':'' ?> ><?php echo $v['title_method']?></option>
	<?php }?>
    </select></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Bulk Process Employer Acc</td>
    <td colspan="2" bgcolor="#CCCCCC"><label for="super_bulk_employee_id">
      <input type="text" name="super_bulk_employer_acc_no" id="super_bulk_employer_acc_no" value="<?php echo $this->stLine['super_bulk_employer_acc_no']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> />
    </label></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Bulk Process Employee No</td>
    <td colspan="2" bgcolor="#CCCCCC"><input type="text" name="super_bulk_employee_id" id="super_bulk_employee_id" value="<?php echo $this->stLine['super_bulk_employee_id']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td bgcolor="#FFFFFF">Bay Pay Biller Code</td>
    <td colspan="2" bgcolor="#FFFFFF"><input type="text" name="super_bpay_biller_code" id="super_bpay_biller_code"  value="<?php echo $this->stLine['super_bpay_biller_code']?>"  <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>  /></td>
  </tr>
  <tr>
    <td bgcolor="#FFFFFF">Bay Pay Reference</td>
    <td colspan="2" bgcolor="#FFFFFF"><input type="text" name="super_bpay_reference" id="super_bpay_reference"  value="<?php echo $this->stLine['super_bpay_reference']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>   /></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Super Acc Name</td>
    <td colspan="2" bgcolor="#CCCCCC"><input type="text" name="super_acc_name" id="super_acc_name"  value="<?php echo $this->stLine['super_acc_name']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>  /></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Super Acc BSB</td>
    <td colspan="2" bgcolor="#CCCCCC"><input type="text" name="super_acc_bsb" id="super_acc_bsb"  value="<?php echo $this->stLine['super_acc_bsb']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Super Acc No.</td>
    <td colspan="2" bgcolor="#CCCCCC"><input type="text" name="super_acc_no" id="super_acc_no"   value="<?php echo $this->stLine['super_acc_no']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>  /></td>
  </tr>
  <tr>
    <td>Pay Frequency</td>
    <td colspan="2"><label for="super_pay_frequency"></label>
      <select name="super_pay_frequency" id="super_pay_frequency" <?php echo (!$this->enableSave)?'disabled = "disabled"':'';?> >
      <option selected="selected">Please Select</option>
        <option value="3" <?php echo ($this->stLine['super_pay_frequency'] == 3)?'selected="selected"':''; ?>>3 Months</option>
        <option value="1" <?php echo ($this->stLine['super_pay_frequency'] == 1)?'selected="selected"':''; ?>>Every Month</option>
      </select></td>
  </tr>

  <tr>
    <td colspan="3" align="center" bgcolor="#CCCCCC"><h2 style="color:#069"> ( Personal ID )</h2></td>
    </tr>
  <tr>
    <td bgcolor="#CCCCCC">Passport No.*:</td>
    <td bgcolor="#CCCCCC" colspan="2"><input name="passport_no" type="text" class="ipt" id="passport_no" value="<?php echo Model_EncryptHelper::getSslPassword($this->stLine['no_passport']); ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>   />
    <?php 
	if($this->psFileExist !=''){
	?>
    <span style="float:right;"><a href="<?php echo $this->psFileExist?>" target="_blank"><img src="/im/img-icon.png" border="0" title="Click To Check Uploaded Photo Copy" alt="Check Detail" /></a></span>
    <?php }?>
    </td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Driver's License No.*:</td>
    <td bgcolor="#CCCCCC" colspan="2"><input name="driver_license" type="text" class="ipt" id="driver_license" value="<?php echo Model_EncryptHelper::getSslPassword($this->stLine['driver_license']); ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>  />
    <?php 
	if($this->dlFileExist !=''){
	?>
    <span style="float:right;"><a href="<?php echo $this->dlFileExist?>" target="_blank"><img src="/im/img-icon.png" border="0" title="Click To Check Uploaded Photo Copy" alt="Check Detail" /></a></span>
    <?php }?>
    </td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Visa Type*:</td>
    <td bgcolor="#CCCCCC" colspan="2">
    <?php
    $visaType = Model_EncryptHelper::getSslPassword($this->stLine['visa_type']);
	?>
    <select name="visa_type" id="visa_type" <?php echo (!$this->enableSave)?'disabled = "disabled"':'';?> >    
      <option value="">-Please Select-</option>
      <option value="International Student"  <?php echo ($visaType == 'International Student')?'selected="selected"':''?>  >International Student</option>
      <option value="Working Holiday" <?php echo ($visaType == 'Working Holiday')?'selected="selected"':''?>  >Working Holiday</option>
      <option value="Permanent Residency" <?php echo ($visaType == 'Permanent Residency')?'selected="selected"':''?> >Permanent Residency</option>
      <option value="Australian Citizen Ship" <?php echo ($visaType == 'Australian Citizen Ship')?'selected="selected"':''?> >Australian Citizen Ship</option>
      <option value="New Zealand Citien Ship" <?php echo ($visaType == 'New Zealand Citien Ship')?'selected="selected"':''?> >New Zealand Citizen Ship</option>
      <option value="Temporary Residency" <?php echo ($visaType == 'Temporary Residency')?'selected="selected"':''?> >Temporary Residency</option>
      <option value="Bridging Visa" <?php echo ($visaType == 'Bridging Visa')?'selected="selected"':''?> >Bridging Visa</option>
      <option value="Other" <?php echo ($visaType == 'Other')?'selected="selected"':''?> >Other Visa With Work Permit</option>
    </select>
    <?php 
	if($this->pvFileExist !=''){
	?>
    <span style="float:right;"><a href="<?php echo $this->pvFileExist?>" target="_blank"><img src="/im/img-icon.png" border="0" title="Click To Check Uploaded Photo Copy" alt="Check Detail" /></a></span>
    <?php }?>
    </td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Visa Expire Date*:<br />
      <span style="font-size:12px;">[Write &quot;Permanent&quot; if there is no expire date]</span></td>
    <td bgcolor="#CCCCCC" colspan="2"><input name="visa_date" type="text" class="ipt" id="visa_date" value="<?php echo Model_EncryptHelper::getSslPassword($this->stLine['visa_date']); ?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>  /></td>
  </tr>
  <tr>
    <td colspan="3" align="center" bgcolor="#CCCCCC"><h2 style="color:#069"> ( Payment Type)</h2></td>
    </tr>
  <tr>
    <td bgcolor="#CCCCCC">Card ID</td>
    <td bgcolor="#CCCCCC" colspan="2"><label for="id_card"></label>
      <input name="id_card" type="text" id="id_card" value="<?php echo $this->stLine['id_card']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Record ID (Bank):</td>
    <td bgcolor="#CCCCCC" colspan="2"><input name="id_record_bank" type="text" id="id_record_bank" value="<?php echo $this->stLine['id_record']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Record ID (Cash):</td>
    <td bgcolor="#CCCCCC" colspan="2"><input name="id_record_cash" type="text" id="id_record_cash" value="<?php echo $this->stLine['id_record_cash']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>  /></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Current Type (A-F):</td>
    <td bgcolor="#CCCCCC" colspan="2"><label for="id_package"></label>
      <select name="id_package" id="id_package" <?php echo (!$this->enableSave)?'disabled = "disabled"':'';?> >
      <option selected="selected" disabled="true">--Please Select --</option>
      <optgroup label="Bank Group">
      <?php 
	  
	  $arrBank = array(1,3,4,6,7,8);
	  $arrCash = array(2,5);
	  foreach($arrBank as $idPackage ) {?>
         <option value="<?php echo $idPackage?>" <?php echo ($this->stLine['id_package'] == $idPackage )?'selected="selected"':''; ?> ><?php echo $arrType[$idPackage][0]."(".$arrType[$idPackage][1].")";?></option>             
      <?php }?>
      </optgroup>
<optgroup label="Cash Group">
	 <?php foreach($arrCash as $idPackage ) {?>
         <option value="<?php echo $idPackage?>" <?php echo ($this->stLine['id_package'] == $idPackage )?'selected="selected"':''; ?> ><?php echo $arrType[$idPackage][0]."(".$arrType[$idPackage][1].")";?></option>
      <?php }?>      
</optgroup>
      </select></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Effective Date:</td>
    <td bgcolor="#CCCCCC" colspan="2"><input name="new_package_date" type="text" id="new_package_date" value="<?php echo $this->stLine['new_package_date']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>  /></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Old Type(A-F):</td>
    <td bgcolor="#CCCCCC" colspan="2"><select name="old_id_package" id="old_id_package" <?php echo (!$this->enableSave)?'disabled = "disabled"':'';?> >
    <option selected="selected" disabled="true">--Please Select --</option>
      <optgroup label="Bank Group">
        <?php 
	  
	  $arrBank = array(1,3,4,6,7,8);
	  $arrCash = array(2,5);
	  foreach($arrBank as $idPackage ) {?>
	  	
        <option value="<?php echo $idPackage?>" <?php echo ($this->stLine['old_id_package'] == $idPackage )?'selected="selected"':''; ?> ><?php echo $arrType[$idPackage][0]."(".$arrType[$idPackage][1].")";?></option>
        <?php }?>
        </optgroup>
      <optgroup label="Cash Group">
        <?php foreach($arrCash as $idPackage ) {?>
        <option value="<?php echo $idPackage?>" <?php echo ($this->stLine['old_id_package'] == $idPackage )?'selected="selected"':''; ?> ><?php echo $arrType[$idPackage][0]."(".$arrType[$idPackage][1].")";?></option>
        <?php }?>
        </optgroup>
    </select></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Old Type Change Date:</td>
    <td bgcolor="#CCCCCC" colspan="2"><input name="old_package_date" type="text" id="old_package_date" value="<?php echo $this->stLine['old_package_date']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>  /></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Old Pay Rate:</td>
    <td bgcolor="#CCCCCC" colspan="2"><label for="old_rate"></label>
      <input name="old_rate" type="text" id="old_rate" value="<?php echo $this->stLine['old_rate']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Old Pay Rate Date:</td>
    <td bgcolor="#CCCCCC" colspan="2"><input name="old_rate_date" type="text" id="old_rate_date" value="<?php echo $this->stLine['old_rate_date']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> />
      (yyyy-mm-dd)</td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">New Pay Rate:</td>
    <td bgcolor="#CCCCCC" colspan="2"><input name="new_rate" type="text" id="new_rate" value="<?php echo $this->stLine['new_rate']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>  /></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">New Pay Rate Date:</td>
    <td bgcolor="#CCCCCC" colspan="2"><input name="new_rate_date" type="text" id="new_rate_date" value="<?php echo $this->stLine['new_rate_date']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> /></td>
  </tr>
  <tr>
  	<td colspan="3" align="center" bgcolor="#CCCCCC"><h2 style="color:#069"> ( Allowance Tab )</h2></td>
  </tr>
  <tr>
    <th align="left" bgcolor="#CCCCCC">Allowance Type</th>
    <th align="center" bgcolor="#CCCCCC" colspan="2">Allowance Ammount/Pay Date</th>
  </tr>
  <tr>
    <td align="left" bgcolor="#CCCCCC">Travel Allowance<input type ="hidden" name ="allow_type[]" id = "allow_type_1" value = "1"></input></td>
    <?php if($this->allowance1){
    	$allowance1 = $this->allowance1;?>
    <td align="left" bgcolor="#CCCCCC" width = "320">Amount:<input type ="text" name ="allow_amt[]"  size = "5" value = "<?php echo $allowance1[0]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input>Start Pay Date:<input type ="text" name ="allow_date[]" id = "allow_date_1" class = "date" size = "10" value = "<?php echo $allowance1[1]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input></td>
    <td align="left" bgcolor="#CCCCCC">Time:<input type ="text" name ="allow_gap[]"  size = "1" value = "<?php echo $allowance1[2]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input> weeks</td>
  	<?php }else{?>
  	<td align="left" bgcolor="#CCCCCC" width = "320">Amount:<input type ="text" name ="allow_amt[]"  size = "5" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input>Start Pay Date:<input type ="text" name ="allow_date[]" id = "allow_date_1" class = "date" size = "10" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input></td>
    <td align="left" bgcolor="#CCCCCC">Time:<input type ="text" name ="allow_gap[]"  size = "1" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input> weeks</td>
  	<?php }?>
  </tr>
  <tr>
    <td align="left" bgcolor="#CCCCCC">Petrol Allowance<input type ="hidden" name ="allow_type[]" id = "allow_type_2" value = "2"></input></td>
     <?php if($this->allowance2){
     	$allowance2 = $this->allowance2;?>
    <td align="left" bgcolor="#CCCCCC" width = "320">Amount:<input type ="text" name ="allow_amt[]"  size = "5" value = "<?php echo $allowance2[0]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input>Start Pay Date:<input type ="text" name ="allow_date[]" id = "allow_date_2" class = "date" size = "10" value = "<?php echo $allowance2[1]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input></td>
  	<td align="left" bgcolor="#CCCCCC">Time:<input type ="text" name ="allow_gap[]"  size = "1" value = "<?php echo $allowance2[2]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input> weeks</td>
  	<?php }else{?>
  	<td align="left" bgcolor="#CCCCCC" width = "320">Amount:<input type ="text" name ="allow_amt[]"  size = "5" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input>Start Pay Date:<input type ="text" name ="allow_date[]" id = "allow_date_2" class = "date" size = "10" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input></td>
  	<td align="left" bgcolor="#CCCCCC">Time:<input type ="text" name ="allow_gap[]"  size = "1" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input> weeks</td>
  	<?php }?>
  </tr>
  <tr>
    <td align="left" bgcolor="#CCCCCC">Stationary Allowance<input type ="hidden" name ="allow_type[]" id = "allow_type_3"value = "3"></input></td>
    <?php if($this->allowance3){
    	$allowance3 = $this->allowance3;?>
    <td align="left" bgcolor="#CCCCCC" width = "320">Amount:<input type ="text" name ="allow_amt[]"  size = "5" value = "<?php echo $allowance3[0]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input>Start Pay Date:<input type ="text" name ="allow_date[]" id = "allow_date_3" class = "date" size = "10" value = "<?php echo $allowance3[1]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input></td>
  	<td align="left" bgcolor="#CCCCCC">Time:<input type ="text" name ="allow_gap[]"  size = "1" value = "<?php echo $allowance3[2]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input> weeks</td>
 	<?php }else{?>
 	<td align="left" bgcolor="#CCCCCC" width = "320">Amount:<input type ="text" name ="allow_amt[]"  size = "5" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input>Start Pay Date:<input type ="text" name ="allow_date[]" id = "allow_date_3" class = "date" size = "10" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input></td>
  	<td align="left" bgcolor="#CCCCCC">Time:<input type ="text" name ="allow_gap[]"  size = "1" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input> weeks</td>
 	<?php }?>
  </tr>
  <tr>
    <td align="left" bgcolor="#CCCCCC">Paper Allowance<input type ="hidden" name ="allow_type[]" id = "allow_type_4" value = "4"></input></td>
    <?php if($this->allowance4){
    	$allowance4 = $this->allowance4;?>
    <td align="left" bgcolor="#CCCCCC" width = "320">Amount:<input type ="text" name ="allow_amt[]"  size = "5" value = "<?php echo $allowance4[0]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input>Start Pay Date:<input type ="text" name ="allow_date[]" id = "allow_date_4" class = "date" size = "10" value = "<?php echo $allowance4[1]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input></td>
    <td align="left" bgcolor="#CCCCCC">Time:<input type ="text" name ="allow_gap[]"  size = "1" value = "<?php echo $allowance4[2]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input> weeks</td>
    <?php }else{?>
    <td align="left" bgcolor="#CCCCCC" width = "320">Amount:<input type ="text" name ="allow_amt[]"  size = "5" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input>Start Pay Date:<input type ="text" name ="allow_date[]" id = "allow_date_4" class = "date" size = "10" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input></td>
    <td align="left" bgcolor="#CCCCCC">Time:<input type ="text" name ="allow_gap[]"  size = "1" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input> weeks</td>
    <?php }?>
  </tr>
  <tr>
  	
    <td align="left" bgcolor="#CCCCCC">Overoll Allowance<input type ="hidden" name ="allow_type[]" id = "allow_type_5" value = "5"></input></td>
    <?php if($this->allowance5){
    	$allowance5 = $this->allowance5;?>
    <td align="left" bgcolor="#CCCCCC" width = "320">Amount:<input type ="text" name ="allow_amt[]"  size = "5" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input>Start Pay Date:<input type ="text" name ="allow_date[]" id = "allow_date_5" class = "date" size = "10" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input></td>
  	<td align="left" bgcolor="#CCCCCC">Time:<input type ="text" name ="allow_gap[]"  size = "1" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input> weeks</td>
  	<?php }else{?>
  	<td align="left" bgcolor="#CCCCCC" width = "320">Amount:<input type ="text" name ="allow_amt[]"  size = "5" value = "<?php echo $allowance5[0]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input>Start Pay Date:<input type ="text" name ="allow_date[]" id = "allow_date_5" class = "date" size = "10" value = "<?php echo $allowance5[1]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input></td>
  	<td align="left" bgcolor="#CCCCCC">Time:<input type ="text" name ="allow_gap[]"  size = "1" value = "<?php echo $allowance5[2]?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> ></input> weeks</td>
  	<?php }?>
  </tr>
  <tr>
    <td colspan="3" align="center" bgcolor="#CCCCCC"><h2 style="color:#069"> ( Employee Type/History)</h2></td>
    </tr>
  <tr>
    <td align="left" bgcolor="#CCCCCC">Register Date:</td>
    <td align="left" bgcolor="#CCCCCC" colspan="2"><?php
    echo ($this->stLine['register_date']!="")?$this->stLine['register_date']:'N/A';
	echo " , ";
	$mginfo = new Model_DbTable_Roster_Stafflogindetail();
	if($this->stLine['id_manager_introduce']!=''){
	$mgLine = $mginfo->getDetail($this->stLine['id_manager_introduce']);
	echo "By: ".$mgLine['ni'];
	}

	?></td>
  </tr>
  <tr>
    <td align="left" bgcolor="#CCCCCC">Paper Document Ready:</td>
    <td align="left" bgcolor="#CCCCCC" colspan="2"><input type="radio" name="paper_doc_ready" id="paper_doc_ready1" value="1" <?php echo ($this->stLine['paper_doc_ready']==1)?'checked="checked"':'';?> <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>  />

        Ready
        <input type="radio" name="paper_doc_ready" id="paper_doc_ready2" value="0" <?php echo ($this->stLine['paper_doc_ready']!=1)?'checked="checked"':'';?> <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> />
    
        Incomplete<br />
        <span style="font-size:11px;">(You may extened his password expire date if the paper document still incomplete, you should set the staff password to never expire after paper document ready, <a href="/rosteraudit/extend-password" target="_blank">Click Here</a> to Setup)</span>
      </td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Position</td>
    <td bgcolor="#CCCCCC" colspan="2">
    <?php 
    $pos = new Model_Hr_Staffposition();
    $plist = $pos->listAll();
    ?>
      <select name="position_status" id="position_status" <?php echo (!$this->enableSave)?'disabled = "disabled"':'';?> >
        <option value="0" <?php echo ($this->stLine['position_status']==0)?'selected="selected"':'';?> >-Please Select-</option>
        <?php foreach($plist as $k => $v){?>
        <option value="<?php echo $v['id_position'];?>" <?php echo ($this->stLine['position_status']==$v['id_position'])?'selected="selected"':'';?> ><?php echo $v['title_position'];?></option>
        <?php }?>
      </select></td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Is Leave</td>
    <td bgcolor="#CCCCCC" colspan="2"><input type="radio" name="is_leave" id="radio" value="1" <?php echo ($this->stLine['leave'] == 1)?'checked="checked"':''; ?> <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>   />
Current
  <input type="radio" name="is_leave" id="radio2" value="9" <?php echo ($this->stLine['leave'] == 9)?'checked="checked"':''; ?> <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?> />
Leave</td>
  </tr>
  <tr>
    <td bgcolor="#CCCCCC">Date Leave</td>
    <td colspan="2" bgcolor="#CCCCCC"><input name="date_leave" type="text" id="date_leave" value="<?php echo $this->stLine['leave_date']?>" <?php echo (!$this->enableSave)?'readonly = "readonly"':'';?>  /></td>
  </tr>
  
    
  <tr>
    <td colspan="3" align="center"><br />
      <br /><input type="submit" name="btn_submit" id="btn_submit" value="Save Changes" <?php echo ($this->enableSave)?'':'disabled="disabled"'?> /></td>
  </tr>
</table>
 </form>
<?php }?> 
</body>



</html>
